<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE html>
<html>
	<head>
	<meta charset="UTF-8">
	<title>Insert title here</title>
	</head>
	<body>
		<% boolean isOk = false; %>
		<form action = "admin_info.jsp" method = "post"> 
				<input type = "submit" value = "返回" />
		</form>
	
		<form action="http://localhost:8083/Car_Pass_Count_System/SelectCarServlet" method="post">
			请输入查询内容：<input type="text" name="selectText">
			<select name="selectType">
				<option value="0">请选择</option>
				<option value="1">根据车牌号</option>
				<option value="2">根据车主</option>
				<option value="3">根据日期</option>
			</select>
			<input type="submit"/>
		</form>
		
		<c:if test = "${ isOk }">
			<table border = "3">
				<tr>
					<th> 车主 </th>
					<th> 车牌 </th>
					<th> 申请时间 </th>
				</tr>
				<c:forEach items = "${ Result }" var = "res">
					<tr>
						<td>
							<c:out value="${ res.username }"/>
						</td>
						<td>
							<c:out value="${ res.car_id }"/>
						</td>
						<td>
							<c:out value="${ res.createTime }"/>
						</td>
					</tr> 
				</c:forEach>
			</table>
		</c:if>
	</body>
</html>